Skip to content

Use ENOMEM return and add goto out on AAD error with linuxkm#9971

Merged
douzzer merged 2 commits intowolfSSL:masterfrom
JacobBarthelmeh:linuxkm
Mar 16, 2026
Merged

Use ENOMEM return and add goto out on AAD error with linuxkm#9971
douzzer merged 2 commits intowolfSSL:masterfrom
JacobBarthelmeh:linuxkm

Conversation

@JacobBarthelmeh
Copy link
Contributor

f-631 & f-669

@JacobBarthelmeh JacobBarthelmeh self-assigned this Mar 13, 2026
Copilot AI review requested due to automatic review settings March 13, 2026 20:09
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Aligns kernel-module error handling with platform conventions by returning -ENOMEM on allocation failures and ensuring early exit/cleanup when AAD processing fails.

Changes:

  • Replace -MEMORY_E with -ENOMEM for allocation failures in Linux KM AES init paths.
  • Add goto to a common exit path on AAD error in GCM work handling.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
linuxkm/lkcapi_aes_glue.c Switch allocation-failure returns to Linux-standard -ENOMEM.
bsdkm/wolfkmod.c Jump to shared cleanup/exit path when AAD setup reports an error.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@JacobBarthelmeh
Copy link
Contributor Author

Retest this please Jenkins. Windows test connection failure.

@JacobBarthelmeh
Copy link
Contributor Author

JacobBarthelmeh commented Mar 13, 2026

Retest this please Jenkins. Multi-test failure AIL scripts/ocsp-stapling-with-wolfssl-responder.test (exit status: 1)

Copy link
Contributor

@douzzer douzzer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tested with

wolfssl-multi-test.sh ...
quantum-safe-wolfssl-all-crypto-only-intelasm-linuxkm-mainline-insmod
'.*cust-kernel-3.*'

@douzzer
Copy link
Contributor

douzzer commented Mar 16, 2026

note, Jenkins failure was FAIL: scripts/ocsp-stapling2.test in all-c89-clang-tidy, reporting "pid 358166 for port 62522 exited before creating ready file. bailing...". reran locally pro forma and it succeeded (and is nothing to do with the PR in any case).

@douzzer douzzer merged commit 30d8cf1 into wolfSSL:master Mar 16, 2026
445 of 446 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants